package com.yty.order.form;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;

@ApiModel("商品购买详情")
@Data
public class OrderDetailForm {
    @ApiModelProperty("商品id")
    @NotEmpty(message = "产品id不能为空")
    private String productId;

    @ApiModelProperty("商品数量")
    @NotNull(message = "商品数量必填")
    @DecimalMin(value = "0", inclusive = false, message = "购买数量不能为0")
    private Integer productQuantity;
}
